package cn.yj.core.wechat;

import cn.yj.tools.http.request.AbstractRequest;
import cn.yj.wechat.request.WxHttp;
import lombok.SneakyThrows;

import java.io.File;
import java.util.Map;

/**
 * @author 永健
 * @since 2021-04-29 22:50
 */
public class WxHttpRequest extends AbstractRequest implements WxHttp {

    @SneakyThrows
    @Override
    public Map<String, Object> get(String url, Map<String, Object> param) {
        return httpGet(url, param);
    }

    @SneakyThrows
    @Override
    public Map<String, Object> post(String url, Map<String, Object> param) {
        return httpPost(url, param);
    }

    @Override
    public Map<String, Object> postFile(String url, Map<String, File> file, Map<String, Object> param) throws Exception {
        return postFormDataString(url,file,param);
    }

    @SneakyThrows
    @Override
    public Map<String, Object> delete(String url, Map<String, Object> param) {
        return httpDelete(url, param);
    }

}
